Version control

Always format. This way the versioned files have a consistent format and don't have updates for formatting issues.

If it's easier to generate, generate the code and version control the script that generates it. If it's easier to type the code, type the code and version control it.

For example, it's easier to write xtext grammars by hand than generating them and thus are version controled. it's easier to write a generator for blockly webpages than mantaining the html xml and js files, and thus the generator is version controled.

It's easier to maintain a build script like build.gradle or package.json than all the dependencies, and thus the build scripts are version controled.

Writing the build script is easier than generating it, so we version control the build script instead of generating it.

What about git hook scripts? Generating them would take longer than writing them thus we version control them and install them with the build tool.

Folder structure, if files have same extension, group them in folders. If files need to be in the root folder, put them in the root folder. Examples include package.json, .gitignore, README.md and SUMMARY.md. Otherwise group them in folders. Examples include hooks and guides.

Ideal folder structure: